package jwf.http;

public class Item {
    private String name;
    private String value;
    private String domain;
    private String path;
    private String expires;
    private String version;

    public String text() {
	StringBuffer sb = new StringBuffer();
	sb.append(name).append("=").append(value);
	if (!"".equals(domain)) {
	    sb.append(";Domain=").append(domain);
	}
	if (!"".equals(path)) {
	    sb.append(";Path=").append(path);
	}
	if (!"".equals(expires)) {
	    sb.append(";Expires=").append(expires);
	}
	return sb.toString();
    }

    public String getName() {
	return name;
    }

    public void setName(String name) {
	this.name = name;
    }

    public String getValue() {
	return value;
    }

    public void setValue(String value) {
	this.value = value;
    }

    public String getDomain() {
	return domain;
    }

    public void setDomain(String domain) {
	this.domain = domain;
    }

    public String getPath() {
	return path;
    }

    public void setPath(String path) {
	this.path = path;
    }

    public String getExpires() {
	return expires;
    }

    public void setExpires(String expires) {
	this.expires = expires;
    }

    public String getVersion() {
	return version;
    }

    public void setVersion(String version) {
	this.version = version;
    }

}